package lancs.mobilemedia.core.ui.controller;

import java.io.IOException;
import java.io.OutputStream;

import javax.microedition.io.Connector;
import javax.microedition.io.SocketConnection;

public class TracerController {

	public void sendInformation(String info) {
		try {
			SocketConnection sc = (SocketConnection) Connector.open("socket://localhost:6666");
			OutputStream os = null;
			try {
				os = sc.openOutputStream();
				byte[] data = info.getBytes();
				os.write(data);
			} finally {
				sc.close();
				os.close();
			}
		} catch (IOException x) {
			x.printStackTrace();
		}
	}

}
